home *** CD-ROM | disk | FTP | other *** search
/ The Sunday Times: Parent Power / The Sunday Times - Parent Power.iso / pc / engine / schools_of_year.swf / scripts / frame_1 / DoAction.as
Encoding:
Text File  |  2005-11-02  |  683 b   |  28 lines

  1. function init()
  2. {
  3.    assignSchoolsBtnHandlers();
  4. }
  5. function assignSchoolsBtnHandlers()
  6. {
  7.    var _loc2_ = this;
  8.    var _loc3_ = 6;
  9.    var _loc1_ = 1;
  10.    while(_loc1_ <= _loc3_)
  11.    {
  12.       _loc2_["btnSchools" + _loc1_].schoolNum = _loc1_;
  13.       _loc2_["btnSchools" + _loc1_].onPress = function()
  14.       {
  15.          _parent.movie_load("school" + this.schoolNum + ".swf");
  16.       };
  17.       _loc2_["btnSchools" + _loc1_].onRollOver = function()
  18.       {
  19.          this._parent.gotoAndStop(this.schoolNum + 3);
  20.       };
  21.       _loc2_["btnSchools" + _loc1_].onRollOut = function()
  22.       {
  23.          this._parent.gotoAndStop(3);
  24.       };
  25.       _loc1_ = _loc1_ + 1;
  26.    }
  27. }
  28.